<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">

<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title>INSPINIA | Login 2</title>

    <link  th:href="@{/css/bootstrap.min.css}" rel="stylesheet">
    <link th:href="@{/font-awesome/css/font-awesome.css}" rel="stylesheet">

    <link th:href="@{/css/animate.css}" rel="stylesheet">
    <link th:href="@{/css/style.css}" rel="stylesheet">

</head>

<body class="gray-bg">

    <div class="loginColumns animated fadeInDown">
        <div class="row">
            <div class="col-md-6">
                <div style="margin:150px 0 80px; text-align: center"><span>您已被踢出！ 点此<a th:href="@{/login}">重新登录</a></span></div>
            </div>
        </div>
        <hr/>
        <div class="row">
            <div class="col-md-6">
                Copyright Example Company
            </div>
            <div class="col-md-6 text-right">
               <small>© 2014-2015</small>
            </div>
        </div>
    </div>
    <!-- Mainly scripts -->
    <script src="js/jquery-3.1.1.min.js"></script>
    <script>
        $(function(){
            $("#loginBtn").on("click",function(){
                $.post({
                   url:"/login",
                   dataType:"json",
                   data:$("#loginForm").serialize(),
                   success:function(data){
                       if(data.ret){
                           window.location.href = "/index";
                       }else{
                            $("#LoginInfo").text(data.msg);
                           }
                       }
                   })
                });

                $(document).keyup(function (event) {
                    if (event.keyCode == 13) {
                    $("#loginBtn").click();
                }
            });


        })
    </script>

</body>

</html>
